<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Menu manager</title>
</head>
<body>

	<jsp:include page="../../common/bar.jsp"></jsp:include>

	<!--  nav class="navbar navbar-inverse navbar-fixed-top">
		<div class="container-fluid">
			<div class="navbar-header">
				<a class="navbar-brand" href="#" id="storeName"></a>
			</div>
			<div id="navbar" class="navbar-collapse collapse">

				<form class="navbar-form navbar-right">
					<input type="text" class="form-control" placeholder="Search menu">
				</form>

			</div>
		</div>
	</nav>-->

	<div class="container-fluid">
		<div class="row">
			<div class="col-sm-1 col-md-1 sidebar">
				<ul class="nav nav-sidebar">
					<li><a data-toggle="tab">Home<span class="sr-only">(current)</span></a></li>

					<li class="active" id="m_manager"><a href="#menumanager"
						data-toggle="tab">Menu Manager<span class="sr-only">(current)</span></a></li>
					<li id="o_manager"><a href="#ordermanager" data-toggle="tab">Order
							Manager<span class="sr-only">(current)</span>
					</a></li>
					<li id="a_manager"><a href="#assessmanager" data-toggle="tab">Assess
							Manager<span class="sr-only">(current)</span>
					</a></li>
				</ul>
			</div>

			<div class="tab-content">

				<div
					class="col-sm-10 col-sm-offset-1 col-md-11 col-md-offset-1 main tab-pane active"
					id="menumanager">
					<h2 class="sub-header">Menu List</h2>
					<button type="button" class="btn btn-primary add_btn"
						data-toggle="modal" data-target="#addModal">Add Menu</button>


					<div class="table-responsive">
						<table class="table table-striped">
							<thead>
								<tr>
									<th>Id</th>
									<th>Name</th>
									<th>Price</th>
									<th>Img</th>
									<th>Type</th>
									<th>Modify</th>
									<th>Delete</th>
								</tr>
							</thead>
							<tbody id="menus">

							</tbody>
						</table>
					</div>
				</div>

				<div
					class="col-sm-10 col-sm-offset-1 col-md-11 col-md-offset-1 main tab-pane"
					id="ordermanager">
					<h2 class="sub-header">Order List</h2>
					<button type="button" class="btn btn-primary" id="u_order">Untreated
						order</button>
					<button type="button" class="btn btn-primary" id="r_order">Receive
						order</button>

					<button type="button" class="btn btn-primary" id="f_order">Finish
						order</button>

					<br>

					<div class="panel-group" style="padding-top: 20px" id="orders"></div>

					<!--  <div class="col-md-10 col-md-offset-1"></div>-->


				</div>

				<div
					class="col-sm-10 col-sm-offset-1 col-md-11 col-md-offset-1 main tab-pane"
					id="assessmanager">
					<h2 class="sub-header">Assess List</h2>
					<button type="button" class="btn btn-primary add_btn">Add
						Menu</button>


				</div>


			</div>

		</div>

		﻿
		
		
		<jsp:include page="../../common/img.jsp"></jsp:include>



		<div class="modal fade" id="addModal" tabindex="-1" role="dialog"
			aria-labelledby="addLabel">
			<div class="modal-dialog" role="document">
				<div class="modal-content">
					<div class="modal-header">
						<button type="button" class="close" data-dismiss="modal"
							aria-label="Close">
							<span aria-hidden="true">&times;</span>
						</button>
						<h4 class="modal-title" id="addLabel">Add Menu</h4>
					</div>
					<div class="modal-body">
						<form enctype="multipart/form-data">
							<label for="name">Name</label> <input type="text"
								class="form-control" id="add_name" placeholder="pls input name">

							<br> <label for="name">Price</label> <input type="number"
								step="0.01" class="form-control" placeholder="pls input price"
								id="add_price"> <br> <label class="control-label">Image</label>
							<input id="add_img" name="add_img" type="file"
								class="file btn btn-default" data-show-preview="false"
								style="width: 100%"> <br> <label
								class="control-label">Type</br></label> <select id="add_type"
								class="selectpicker">
								<option value="8a5e9d3d5dde5982015dde5985cb0001">Staple
									food</option>
								<option value="8a5e9d3d5dde5982015dde59858f0000">Drinks</option>
								<option value="8a5e9d3d5dde5982015dde5985ce0002">Snack</option>
								<option value="8a5e9d3d5dde5982015dde5985d00003">Set
									meal</option>
							</select>
						</form>
					</div>
					<div class="modal-footer">
						<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
						<button type="button" id="add_menu" class="btn btn-primary">Add
							menu</button>
					</div>
				</div>
			</div>
		</div>


		<div class="modal fade" id="updateModal" tabindex="-1" role="dialog"
			aria-labelledby="addLabel">
			<div class="modal-dialog" role="document">
				<div class="modal-content">
					<div class="modal-header">
						<button type="button" class="close" data-dismiss="modal"
							aria-label="Close">
							<span aria-hidden="true">&times;</span>
						</button>
						<h4 class="modal-title" id="addLabel">Update Menu</h4>
					</div>
					<div class="modal-body">
						<form enctype="multipart/form-data">

							<input type="hidden" class="form-control" id="update_id">
							<input type="hidden" class="form-control" id="update_imgpath">

							<label for="name">Name</label> <input type="text"
								class="form-control" id="update_name"
								placeholder="pls input name"> <br> <label
								for="name">Price</label> <input type="number" step="0.01"
								class="form-control" placeholder="pls input price"
								id="update_price"> <br> <label
								class="control-label">Image</label> <input id="update_img"
								name="update_img" type="file" class="file btn btn-default"
								data-show-preview="false" style="width: 100%"> <br>
							<label class="control-label">Type</br></label> <select
								id="update_type" class="selectpicker">
								<option value="8a5e9d3d5dde5982015dde5985cb0001">Staple
									food</option>
								<option value="8a5e9d3d5dde5982015dde59858f0000">Drinks</option>
								<option value="8a5e9d3d5dde5982015dde5985ce0002">Snack</option>
								<option value="8a5e9d3d5dde5982015dde5985d00003">Set
									meal</option>
							</select>


						</form>
					</div>
					<div class="modal-footer">
						<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
						<button type="button" id="update_menu" class="btn btn-primary">Update
							menu</button>
					</div>
				</div>
			</div>
		</div>


		<div class="table-responsive" id="orderTemplate"
			style="display: none; padding-top: 20px">

			<div class="panel panel-primary">
				<div class="panel-heading" data-toggle="collapse"
					data-parent="#accordion" href="#collapseOne">
					<h4 class="panel-title" style="height: 96px">

						<img class="img-circle"
							src="http://10.222.29.189:9000/food/23877ae3-3693-4df4-b4f3-ef52fa23c1b0.jpg"
							width="70px" height="70px"
							style="float: left; text-align: center" />&nbsp;&nbsp;&nbsp; <span
							class="cname" style="font-size: 24px; padding-left: 24px">name</span>&nbsp;&nbsp;&nbsp;<br>
						<span class="pull-right currenttime"></span>
						<hr
							style="width: 22%; border: 1px solide #ccc; margin-left: 95px;"
							class="col-sm-offset-1"></hr>
						<span class="id" style="padding-left: 25px;">id</span> <span
							class="col-sm-offset-2 total" style="margin-left: 200px;">total
						</span>

						<div class="pull-right btn-group">
							<button type="button" class="btn btn-success" id="receive_btn"
								style="display: none; margin-right: 25px;">Receive</button>

							<button type="button" class="btn btn-danger" id="refuse_btn"
								style="display: none; width =24px; margin-top: 1px;">Refuse</button>
							<button type="button" class="btn btn-warning" id="delivery_btn"
								style="display: none;">Delivery</button>
						</div>


					</h4>
				</div>
				<div id="collapseOne"
					class="panel-collapse collapse in panel-default">
					<div class="panel-body"></div>
				</div>
			</div>

		</div>


		<input type="hidden" class="mid" id="mid" value="${m.id}">
		
</body>


</html>